﻿@using BBSSite.ViewModels <!--引用命名空间-->
@model LoginUsersByCustomerEntity
@{
    Layout = "";//指定Layout为空
    MyPublic.IGettingUrl Urls = ViewBag.Urls as MyPublic.IGettingUrl;
}

<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <title>明日科技-登录</title>
    <link href="@Urls.ContentBootstrapUrl/bootstrap.min.css" rel="stylesheet">
    <script src="@Urls.ScriptUrl/jquery-3.1.1.min.js"></script>
    <script src="@Urls.ScriptUrl/bootstrap.min.js"></script>
    <script type="text/javascript" src="@Urls.ContentJSUrl/login.js?v=0.3"></script>

    <style type="text/css">
        html,body {
	        height: 100%;
        }
        .box {
	        filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#6699FF', endColorstr='#6699FF'); /*  IE */
	        background-image:linear-gradient(bottom, #6699FF 0%, #6699FF 100%);
	        background-image:-o-linear-gradient(bottom, #6699FF 0%, #6699FF 100%);
	        background-image:-moz-linear-gradient(bottom, #6699FF 0%, #6699FF 100%);
	        background-image:-webkit-linear-gradient(bottom, #6699FF 0%, #6699FF 100%);
	        background-image:-ms-linear-gradient(bottom, #6699FF 0%, #6699FF 100%);

	        margin: 0 auto;
	        position: relative;
	        width: 100%;
	        height: 100%;
        }
        .login-box {
	        width: 100%;
	        max-width:500px;
	        height: 400px;
	        position: absolute;
	        top: 50%;
	        margin-top: -200px;
	        /*设置负值，为要定位子盒子的一半高度*/

        }
        @@media screen and (min-width:500px){
	        .login-box {
		        left: 50%;
		        /*设置负值，为要定位子盒子的一半宽度*/
		        margin-left: -250px;
	        }
        }
        .form {
	        width: 100%;
	        max-width:500px;
	        height: 275px;
	        margin: 25px auto 0px auto;
	        padding-top: 25px;
        }
        .login-content {
	        height: 300px;
	        width: 100%;
	        max-width:500px;
	        background-color: rgba(255, 250, 2550, .6);
	        float: left;
        }


        .input-group {
	        margin: 0px 0px 30px 0px !important;
        }
        .form-control,
        .input-group {
	        height: 40px;
        }

        .form-group {
	        margin-bottom: 0px !important;
        }
        .login-title {
	        padding: 20px 10px;
	        background-color: rgba(0, 0, 0, .6);
        }
        .login-title h1 {
	        margin-top: 10px !important;
        }
        .login-title small {
	        color: #fff;
        }

        .link p {
	        line-height: 20px;
	        margin-top: 30px;
        }
        .btn-sm {
	        padding: 8px 24px !important;
	        font-size: 16px !important;
        }
    </style>

</head>

<body>
    <!--登录页面背景-->
    <div class="box" style="background-image: url('@Urls.ContentImagesUrl/loginBack.png');background-size:100%;">
        <div class="login-box"><!--布局登录控件位置-->
            <div class="login-title text-center"><!--登录状态标题信息容器-->
                <h1><small>@Html.ValidationMessage("LoginError",new { style="color:red;"})</small></h1>
            </div>
            <div class="login-content "><!--登录控件容器-->
                <div class="form">
                    <!--定义form标签，指定控制器为Account，执行动作为DoLogin-->
                    @using (Html.BeginForm("DoLogin", "Account", FormMethod.Post, new { id = "loginform" }))
                    {
                        @Html.AntiForgeryToken()
                        <div class="form-group">
                            <div class="col-xs-12 ">
                                <div class="input-group">
                                    <span class="input-group-addon"><span class="glyphicon glyphicon-user"></span></span>
                                    @Html.TextBoxFor(TB=>TB.UserName,new { @class= "form-control", placeholder= "用户名" })
                                </div>
                            </div>
                        </div>
                        <div class="form-group">
                            <div class="col-xs-12  ">
                                <div class="input-group">
                                    <span class="input-group-addon"><span class="glyphicon glyphicon-lock"></span></span>
                                    @Html.PasswordFor(PW=>PW.UserPassword,new { @class = "form-control", placeholder = "密码" })
                                </div>
                            </div>
                        </div>
                        <div class="form-group form-actions">
                            <div class="col-xs-4 col-xs-offset-4 ">
                                <button type="submit" class="btn btn-sm btn-info"><span class="glyphicon glyphicon-off"></span> 登录</button>
                            </div>
                        </div>
                        <div class="form-group">
                            <div class="col-xs-6 link"><p class="text-center remove-margin"></p></div>
                            <div class="col-xs-6 link">
                                <p class="text-center remove-margin">
                                    <small>还没注册?</small> <a href="/Account/Register"><small>注册</small></a>
                                </p>
                            </div>
                        </div>
                    }
                </div>
            </div>
        </div>
    </div>  
</body>
</html>